﻿using System.Collections.Generic;
using System.Reflection;
using msilgc.cbuilder;

namespace msilgc.driver.cuda
{
    internal sealed class CudaMethodNameMapper : IMethodNameMapper
    {
        private readonly IDictionary<string, string> _dotNetToCudaMethodNameMap =
            new Dictionary<string, string>
                {
                    {"Printf", "cuPrintf"},
                    {"SinF", "__sinf"},
                    {"CosF", "__cosf"},
                    {"TanF", "__tanf"},
                };
        public string MapMethodToName(MethodBase method) {
            return _dotNetToCudaMethodNameMap[method.Name];
        }
    }
}
